<template>
  <div class="table_message">
    <tableView :tableData="tableData" v-model="rowClick">
      <template v-slot:searchCondition>
        <el-form label-position="left" label-width="auto">
          <el-row :gutter="20">
            <el-col :span="6">
              <el-form-item label="测试测试">
                <el-input></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="测试测试">
                <el-input></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="测试测试">
                <el-input></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="测试测试">
                <el-input></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="测试测试">
                <el-input></el-input>
              </el-form-item>
            </el-col>
            <el-col :span="6">
              <el-form-item label="测试测试">
                <el-input></el-input>
              </el-form-item>
            </el-col>
          </el-row>
        </el-form>
      </template>
      <template #table-column>
        <el-table-column prop="date" label="时间"></el-table-column>
        <el-table-column prop="name" label="名字"></el-table-column>
        <el-table-column prop="address" label="地址"></el-table-column>
      </template>
    </tableView>
  </div>
</template>

<script>
import tableView from "@/components/table_view/index";
export default {
  name: 'table_message',
  components: { tableView },
  data() {
    return {
      rowClick: {},
      tableData: {
        pageNum: 1,
        pageSize: 10,
        total: 20,
        list: [
          {
            date: "2016-05-02",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1518 弄",
          },
          {
            date: "2016-05-04",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1517 弄",
          },
          {
            date: "2016-05-01",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1519 弄",
          },
          {
            date: "2016-05-03",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1516 弄",
          },
          {
            date: "2016-05-03",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1516 弄",
          },
          {
            date: "2016-05-03",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1516 弄",
          },
          {
            date: "2016-05-03",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1516 弄",
          },
          {
            date: "2016-05-03",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1516 弄",
          },
          {
            date: "2016-05-03",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1516 弄",
          },
          {
            date: "2016-05-03",
            name: "王小虎",
            address: "上海市普陀区金沙江路 1516 弄",
          },
        ],
      },
    };
  },
  watch: {
    rowClick() {
      console.log(this.rowClick);
    },
  },
};
</script>

<style lang='scss' scoped>
.table_message {
  height: 100%;
}
</style>